package com.ruoyi.system.api;

import com.ruoyi.common.core.constant.SecurityConstants;
import com.ruoyi.common.core.constant.ServiceNameConstants;
import com.ruoyi.common.core.domain.R;
import com.ruoyi.system.api.domain.SysConfig;
import com.ruoyi.system.api.factory.RemoteOrgConfigServiceFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;

import java.util.List;

@FeignClient(contextId = "remoteOrgConfigService", value = ServiceNameConstants.SYSTEM_SERVICE, fallbackFactory = RemoteOrgConfigServiceFallbackFactory.class)
public interface RemoteOrgConfigService {


    @PostMapping("/org/config/configList")
    public R<List<SysConfig>> configList(@RequestBody SysConfig sysConfig, @RequestHeader(SecurityConstants.FROM_SOURCE) String source);


}
